home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Visual Database / Visual Foxpro 6.0 (Ent. Edition) / Vf6ent Extractor.EXE / TOOLS / CONVERT / TRANSPRT.H < prev    next >
Encoding:
Text File  |  1998-05-26  |  11.5 KB  |  303 lines

  1. *
  2. * Define Global Constants
  3. *
  4. #DEFINE debugversion     .T.    && enables asserts.  Should usually be .T.
  5.  
  6. *- used in Windows VFP 3.0 conversion dialog
  7. #DEFINE C_MSGBOXTITLE_LOC    "Converter"
  8. #DEFINE C_ASK1_LOC            "Ask for each file;Don't ask for "        && new radio to prevent showing dialog during conversion
  9. #DEFINE C_ASK2_LOC            " files;Don't ask for any files"        && new radio to prevent showing dialog during conversion
  10.  
  11. #DEFINE C_OVERWRITE1_LOC        "Transporting All Objects will overwrite all existing "
  12. * Filetype constants for FoxPro 2.0 and FoxPro 2.5/2.6 formats
  13. #DEFINE C_OVERWRITE2_LOC        " object definitions in the file." 
  14.  
  15. #DEFINE MB_OKCANCEL             1       && OK and Cancel buttons
  16. #DEFINE IDCANCEL                2       && Cancel button pressed
  17.  
  18. * Filetype constants for FoxPro 2.0 and FoxPro 2.5/2.6 formats
  19. #DEFINE c_20pjxtype        1
  20. #DEFINE c_25scxtype       12
  21. #DEFINE c_20scxtype        2
  22. #DEFINE c_25frxtype       13
  23. #DEFINE c_20frxtype        3
  24. #DEFINE c_25lbxtype       14
  25. #DEFINE c_20lbxtype        4
  26.  
  27. *- indexes into gAShowMe array, controls display of transporter dialog for various file types
  28. #DEFINE N_MAXTRANFILETYPES    3                && number of file types that transporter can handle (All,PJX, SCX, FRX)
  29. #DEFINE N_TRANFILE_PJX    1
  30. #DEFINE N_TRANFILE_SCX    2
  31. #DEFINE N_TRANFILE_FRX    3
  32.  
  33. * FoxPro 1.02 and FoxBASE+ formats.  Note that the FoxBASE+ types are never
  34. * actually passed in m.tp_filetype.  They are inferred in GetOldReportType and
  35. * GetOldLabelTypefrom the ID byte in the report/label files.  The suffix tells
  36. * us how the file was called, by REPORT FORM ... or by MODIFY REPORT ...
  37. #DEFINE c_frx102repo      23
  38. #DEFINE c_frx102modi      33
  39. #DEFINE c_fbprptrepo      43
  40. #DEFINE c_fbprptmodi      53
  41. #DEFINE c_lbx102repo      24
  42. #DEFINE c_lbx102modi      34
  43. #DEFINE c_fbplblrepo      44
  44. #DEFINE c_fbplblmodi      54
  45. #DEFINE c_db4type          70
  46.  
  47. * Definitions for Objtype fields in screens/reports/labels
  48. #DEFINE c_otheader         1
  49. #DEFINE c_otworkar         2
  50. #DEFINE c_otindex          3
  51. #DEFINE c_otrel            4
  52. #DEFINE c_ottext           5
  53. #DEFINE c_otline           6
  54. #DEFINE c_otbox            7
  55. #DEFINE c_otrepfld         8
  56. #DEFINE c_otband           9
  57. #DEFINE c_otgroup         10
  58. #DEFINE c_otlist          11
  59. #DEFINE c_ottxtbut        12
  60. #DEFINE c_otradbut        13
  61. #DEFINE c_otchkbox        14
  62. #DEFINE c_otfield         15
  63. #DEFINE c_otpopup         16
  64. #DEFINE c_otpicture       17
  65. #DEFINE c_otrepvar        18
  66. #DEFINE c_ot20lbxobj      19
  67. #DEFINE c_otinvbut        20
  68. #DEFINE c_otpdset         21
  69. #DEFINE c_otspinner       22
  70. #DEFINE c_otfontdata      23
  71.  
  72. #DEFINE C_OBJTYPELIST c_otlist,c_ottxtbut,c_otbox,c_otradbut,c_otchkbox,c_otfield, c_otpopup,c_otinvbut,c_otspinner,c_otpicture,c_otline,c_otrepfld,c_otrepvar,c_ottext
  73.  
  74. * Window types
  75. #DEFINE c_user             1
  76. #DEFINE c_system           2
  77. #DEFINE c_dialog           3
  78. #DEFINE c_alert            4
  79.  
  80. * ObjCode definitions
  81. #DEFINE c_sgsay            0
  82. #DEFINE c_sgget            1
  83. #DEFINE c_sgedit           2
  84. #DEFINE c_sgfrom           3
  85. #DEFINE c_sgbox            4
  86. #DEFINE c_sgboxd           5
  87. #DEFINE c_sgboxp           6
  88. #DEFINE c_sgboxc           7
  89.  
  90. #DEFINE c_lnvertical       0
  91. #DEFINE c_lnhorizontal     1
  92.  
  93. #DEFINE c_ocboxgrp         1
  94.  
  95. * Attempt to preserve colors of text, lines and boxes when transporting to DOS?
  96. #DEFINE c_maptextcolor     .T.
  97.  
  98. * Field counts
  99. #DEFINE c_20scxfld        57
  100. #DEFINE c_scxfld          79
  101. #DEFINE c_20frxfld        36
  102. #DEFINE c_frxfld          74
  103. #DEFINE c_frx30fld        75        && field count for 3.0 FRX file (11/1/95 jd)
  104. #DEFINE c_ot20label       30
  105. #DEFINE c_20lbxfld        17
  106. #DEFINE c_20pjxfld        33
  107. #DEFINE c_pjxfld          31
  108.  
  109. * Strings for product names
  110. #DEFINE c_foxwin_loc   "FoxPro for Windows"
  111. #DEFINE c_foxmac_loc   "FoxPro for Macintosh"
  112. #DEFINE c_foxdos_loc   "FoxPro for MS-DOS/UNIX"
  113. #DEFINE c_winname  "WINDOWS"
  114. #DEFINE c_macname  "MAC"
  115. #DEFINE c_dosname  "DOS"
  116. #DEFINE c_unixname "DOS"
  117. #DEFINE c_dosnum    1
  118. #DEFINE c_winnum    2
  119. #DEFINE c_macnum    3
  120. #DEFINE c_unixnum   4
  121.  
  122. * Metrics for various objects, report bands, etc.
  123. #DEFINE c_radhght      1.308
  124. #DEFINE c_chkhght      1.308
  125. #DEFINE c_listht       1.000
  126. #DEFINE c_adjfld       0.125
  127. #DEFINE c_adjlist      0.125
  128. #DEFINE c_adjtbtn      0.769
  129. #DEFINE c_adjrbtn      0.308
  130. #DEFINE c_vchkbox      0.154
  131. #DEFINE c_vradbtn      0.154
  132. #DEFINE c_vlist        0.500
  133. #DEFINE c_hpopup       1.000
  134. #DEFINE c_adjbox       0.500
  135. #DEFINE c_chkpixel        12
  136.  
  137. #DEFINE c_charrptheight   66
  138. #DEFINE c_charrptwidth    80
  139. #DEFINE c_linesperinch    (66/11)
  140. #DEFINE c_charsperinch    13.71
  141.  
  142. #DEFINE c_pathsep ":"   && path separator character
  143.  
  144. #DEFINE c_mapfonts 3    && number of specially mapped fonts
  145.  
  146. * Version codes, put into Objcode fields in the header record
  147. #DEFINE c_25scx           63
  148. #DEFINE c_25frx           53
  149.  
  150. * Major file types
  151. #DEFINE c_report           0
  152. #DEFINE c_screen           1
  153. #DEFINE c_label            2
  154. #DEFINE c_project          3
  155.  
  156. * Error codes
  157. #DEFINE c_error1   "Minor"
  158. #DEFINE c_error2   "Serious"
  159. #DEFINE c_error3   "Fatal"
  160.  
  161. * Return values
  162. #DEFINE c_yes              1
  163. #DEFINE c_no               0
  164. #DEFINE c_cancel          -1
  165.  
  166. * Codepage translation.
  167. #DEFINE c_cptrans       .T.    && do special CP translation for FoxBASE+ and FoxPro 1.02?
  168. * The following four contants may need to be localized.
  169. #DEFINE c_doscp          437   && default DOS code page
  170. #DEFINE c_wincp         1252   && default Windows code page
  171. #DEFINE c_maccp        10000
  172. #DEFINE c_unixcp           0
  173.  
  174. * bands[] array indexes
  175. #DEFINE c_tobandvpos       1
  176. #DEFINE c_tobandheight     2
  177. #DEFINE c_fmbandvpos       3
  178. #DEFINE c_fmbandheight     4
  179.  
  180. * Frequently used strings.  Make them #DEFINES to simplify localization.
  181. #DEFINE c_converting   "Converting"
  182. #DEFINE c_transporting "Transporting"
  183.  
  184. #DEFINE C_2DCONTROLS_LOC "2D Controls"
  185.  
  186. * Defines used in converting FoxBASE+ reports
  187. #DEFINE maxliterals   55
  188. #DEFINE litpoolsize   1452
  189. #DEFINE maxrepflds   24
  190. #DEFINE h_page   1
  191. #DEFINE h_break 3
  192. #DEFINE l_item   4
  193. #DEFINE f_break 5
  194. #DEFINE f_page   7
  195. #DEFINE f_rpt   8
  196.  
  197. #define c_space 40
  198. #DEFINE dos_code  1
  199. #DEFINE win_code  2
  200. #DEFINE mac_code  3
  201. #DEFINE unix_code 4
  202. #DEFINE c_2dmark '2'
  203. #DEFINE c_3dmark '3'
  204.  
  205. ** New (8/22/95) added for Localization
  206. #DEFINE T_TITLE_LOC "Visual FoxPro Transporter"
  207. #DEFINE T_CONVASIS_LOC "Convert As Is"
  208. #DEFINE T_NOCONV_LOC "If the file is not transported, it will not be converted."
  209. #DEFINE T_NOTRANSPORT_LOC "Don't Transport"
  210. #DEFINE T_RECMOD_LOC " Objects More Recently Modified"
  211. #DEFINE T_NEWMOD_LOC "The objects are new to Windows, or more recently modified than their Windows equivalents."
  212. #DEFINE T_NEWMOD1_LOC "The objects are new to "
  213. #DEFINE T_NEWMOD2_LOC ", or more "+CHR(13)+"recently modified than their "
  214. #DEFINE T_NEWMOD3_LOC " equivalents."
  215. #DEFINE T_BYTRANS1_LOC  "By transporting this file, you create"
  216. #DEFINE T_BYTRANS2_LOC  " definitions for these objects. "
  217. #DEFINE T_BYTRANS3_LOC  "By transporting this file, you add, update, or " + CHR(13) + "replace "
  218. #DEFINE T_BYTRANS4_LOC  " definitions for objects in the file."
  219. #DEFINE T_BYTRANS5_LOC  "By transporting this file, you add,"
  220. #DEFINE T_BYTRANS6_LOC    "update, or replace MS-DOS definitions"
  221. #DEFINE T_ADDUPDREPL_LOC      "By transporting this file, you add, update, or replace Windows definitions for objects in the file."
  222. #DEFINE T_UPDMSDOSDEF_LOC     "By transporting this file, you add, update, or replace MS-DOS definitions"
  223. #DEFINE T_MSDOSDEF_LOC         "By transporting this file, you create MS-DOS definitions for these objects."
  224. #DEFINE T_OTHERPLAT_LOC        "There are objects in this file defined "+CHR(13)+"for a platform other than "
  225. #DEFINE T_OTHERPLAT2_LOC    "There are objects in this file defined"
  226. #DEFINE T_OTHERPLAT3_LOC    "for a platform other than MS-DOS."
  227. #DEFINE T_NODOSDEF_LOC         "There are objects in this file defined for a platform other than MS-DOS."
  228. #DEFINE T_OPENASIS_LOC "Open As Is"
  229. #DEFINE T_NEWDOSOBJ_LOC "Transport Objects New to MS-DOS"
  230. #DEFINE T_TRANSOBJ_LOC "Transport Objects From:"
  231. #DEFINE T_REPLOBJ_LOC "All Objects -- Replace Existing Definitions."
  232. #DEFINE T_REPORT_FILE_LOC "Report File:"
  233. #DEFINE T_LABEL_FILE_LOC  "Label File:"
  234. #DEFINE T_SCREEN_FILE_LOC "Screen File:"
  235. #DEFINE T_SPIN_LOC    "Spinner"
  236. #DEFINE T_SEXPR_LOC    "SAY Expression"
  237. #DEFINE T_GFIELD_LOC    "GET Field"
  238. #DEFINE T_FIELD_LOC    "Field"
  239. #DEFINE T_POPUP_LOC    "Popup"
  240. #DEFINE T_PICTURE_LOC    "Picture"
  241. #DEFINE T_RPTVAR_LOC    "Rpt variable"
  242. #DEFINE T_INVBTN_LOC    "Inv button"
  243. #DEFINE T_PDRIVER_LOC "Printer driver"
  244. #DEFINE T_FONTDATA_LOC "Font data"
  245. #DEFINE T_UNKNOWNVERS_LOC "Unknown FoxPro version."
  246. #DEFINE T_ENERGIZE_LOC "Energize"
  247. #DEFINE    T_SELTRANS_LOC    "Select the file to transport"
  248. #DEFINE T_TRANSPORT_LOC "Transport"
  249. #DEFINE T_TRANSPERR_LOC "Transporter Error"
  250. #DEFINE T_LINENO_LOC    "Line Number: "
  251. #DEFINE T_CLEANUP_LOC    "Press any key to cleanup and exit..."
  252. #DEFINE T_OBJNEWMOD_LOC "These objects are either new to the Windows platform or have been modified more recently"
  253. #DEFINE T_OBJMOD_LOC "These objects have been modified more recently on "
  254. #DEFINE T_OBJNEW1_LOC "These objects are new to "
  255. #DEFINE T_OBJNEW2_LOC " platform or have been modified more recently on "
  256. #DEFINE T_UNCHECK1_LOC "Uncheck any items you do"
  257. #DEFINE T_UNCHECK2_LOC "not"
  258. #DEFINE T_UNCHECK3_LOC "want to be transported."
  259. #DEFINE T_EXPPROMPT_LOC "Expression/Prompt"
  260. #DEFINE T_TYPE_LOC "Type"
  261. #DEFINE T_VARIABLE_LOC "Variable"
  262. #DEFINE T_STAT_LOC "Stat"
  263. #DEFINE T_FONT_LOC "Font"
  264. #DEFINE T_FONT1_LOC "Font..."
  265. #DEFINE T_OK_LOC "OK"
  266. #DEFINE T_CANCEL_LOC "Cancel"
  267. #DEFINE T_TRANSOPEN_LOC "\!Transport & Open;Open As Is;\?Cancel"
  268. #DEFINE T_TRANSOPEN1_LOC "\!Transport & Open;\?Cancel"
  269. #DEFINE T_TRANSOPEN2_LOC "Transport & Open"
  270.  
  271. #DEFINE T_NOSTAND_LOC    "The Transporter cannot be run as a standalone program."
  272. #DEFINE T_INVALIDSCR_LOC    "Invalid screen/report name."
  273. #DEFINE T_WHEREIS_LOC    "Where is "
  274. #DEFINE T_CONVFRX_LOC    "You must convert this file to an .FRX file before you"+CHR(13)+ ;
  275.                         "can use it. Use the Catalog Manager to open the file,"+CHR(13)+ ;
  276.                         "or choose Convert dBASE files from the Run menu."
  277. #DEFINE T_UNKNOWNFRX_LOC    "Unknown report format"
  278. #DEFINE T_TRANSNOTHING_LOC "The transporter has nothing to do." 
  279. #DEFINE T_INVFILEFORMAT_LOC    "Unknown or invalid file format"
  280. #DEFINE T_NORECS_LOC    "No records to transport"
  281. #DEFINE T_COMVPRMPT1_LOC    "Convert 1.02 report file to 2.6 format?"
  282. #DEFINE T_COMVPRMPT2_LOC    "Convert FoxBASE+/dBASE III report file to FoxPro 2.6 format?"
  283. #DEFINE T_COMVPRMPT3_LOC    "Convert 1.02 label file to 2.6 format?"
  284. #DEFINE T_COMVPRMPT4_LOC    "Convert FoxBASE+/dBASE III label file to FoxPro 2.6 format?"
  285. #DEFINE T_COMVPRMPT5_LOC    "Convert 2.0 screen file to 2.6 format?"
  286. #DEFINE T_COMVPRMPT6_LOC    "Convert 2.0 report file to 2.6 format?"
  287. #DEFINE T_COMVPRMPT7_LOC    "Convert 2.0 project file to 2.6 format?"
  288. #DEFINE T_UNKOPERATION_LOC    "Unknown doupdate operation"
  289. #DEFINE T_UNKFOXVER_LOC        "Unknown Version of FoxPro."
  290. #DEFINE T_SAMELINE_LOC        "To and from platforms are the same in line "
  291. #DEFINE T_NOOPENREPT_LOC    "Could not open FoxBASE+ report form"
  292. #DEFINE T_TOTAL1_LOC    "*** Total ***"
  293. #DEFINE T_YESNO_LOC        "\<Yes;\!\?\<No"
  294.  
  295. #DEFINE T_THAN_LOC        "Than "
  296. #DEFINE T_EQIVOBJS_LOC    " Equivalent Objects" 
  297. #DEFINE    T_OBJSNEWTO_LOC    "Objects New to "
  298. #DEFINE    T_OBJINFILE_LOC "for objects in the file."
  299. #DEFINE T_THERMSCR_LOC    " screen: "
  300. #DEFINE T_THERMRPT_LOC    " report: "
  301. #DEFINE T_THERMLBL_LOC    " label: "
  302. #DEFINE T_ASSERTFAIL_LOC    "Assertion failed: "
  303. #DEFINE T_THANMAC_LOC    "Than Macinstosh Equivalent Objects"